3.2.17 \(\int \frac {\sin ^3(e+f x)}{\sqrt {a+b \tan ^2(e+f x)}} \, dx\) [117]

Optimal. Leaf size=88 \[ -\frac {(3 a-b) \cos (e+f x) \sqrt {a-b+b \sec ^2(e+f x)}}{3 (a-b)^2 f}+\frac {\cos ^3(e+f x) \sqrt {a-b+b \sec ^2(e+f x)}}{3 (a-b) f} \]

[Out]

-1/3*(3*a-b)*cos(f*x+e)*(a-b+b*sec(f*x+e)^2)^(1/2)/(a-b)^2/f+1/3*cos(f*x+e)^3*(a-b+b*sec(f*x+e)^2)^(1/2)/(a-b)
/f

________________________________________________________________________________________

Rubi [A]
time = 0.07, antiderivative size = 88, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.120, Rules used = {3745, 464, 270} \begin {gather*} \frac {\cos ^3(e+f x) \sqrt {a+b \sec ^2(e+f x)-b}}{3 f (a-b)}-\frac {(3 a-b) \cos (e+f x) \sqrt {a+b \sec ^2(e+f x)-b}}{3 f (a-b)^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[Sin[e + f*x]^3/Sqrt[a + b*Tan[e + f*x]^2],x]

[Out]

-1/3*((3*a - b)*Cos[e + f*x]*Sqrt[a - b + b*Sec[e + f*x]^2])/((a - b)^2*f) + (Cos[e + f*x]^3*Sqrt[a - b + b*Se
c[e + f*x]^2])/(3*(a - b)*f)

Rule 270

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[(c*x)^(m + 1)*((a + b*x^n)^(p + 1)/(a*
c*(m + 1))), x] /; FreeQ[{a, b, c, m, n, p}, x] && EqQ[(m + 1)/n + p + 1, 0] && NeQ[m, -1]

Rule 464

Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Simp[c*(e*x)^(m +
 1)*((a + b*x^n)^(p + 1)/(a*e*(m + 1))), x] + Dist[(a*d*(m + 1) - b*c*(m + n*(p + 1) + 1))/(a*e^n*(m + 1)), In
t[(e*x)^(m + n)*(a + b*x^n)^p, x], x] /; FreeQ[{a, b, c, d, e, p}, x] && NeQ[b*c - a*d, 0] && (IntegerQ[n] ||
GtQ[e, 0]) && ((GtQ[n, 0] && LtQ[m, -1]) || (LtQ[n, 0] && GtQ[m + n, -1])) &&  !ILtQ[p, -1]

Rule 3745

Int[sin[(e_.) + (f_.)*(x_)]^(m_.)*((a_) + (b_.)*tan[(e_.) + (f_.)*(x_)]^2)^(p_.), x_Symbol] :> With[{ff = Free
Factors[Sec[e + f*x], x]}, Dist[1/(f*ff^m), Subst[Int[(-1 + ff^2*x^2)^((m - 1)/2)*((a - b + b*ff^2*x^2)^p/x^(m
 + 1)), x], x, Sec[e + f*x]/ff], x]] /; FreeQ[{a, b, e, f, p}, x] && IntegerQ[(m - 1)/2]

Rubi steps

\begin {align*} \int \frac {\sin ^3(e+f x)}{\sqrt {a+b \tan ^2(e+f x)}} \, dx &=\frac {\text {Subst}\left (\int \frac {-1+x^2}{x^4 \sqrt {a-b+b x^2}} \, dx,x,\sec (e+f x)\right )}{f}\\ &=\frac {\cos ^3(e+f x) \sqrt {a-b+b \sec ^2(e+f x)}}{3 (a-b) f}+\frac {(3 a-b) \text {Subst}\left (\int \frac {1}{x^2 \sqrt {a-b+b x^2}} \, dx,x,\sec (e+f x)\right )}{3 (a-b) f}\\ &=-\frac {(3 a-b) \cos (e+f x) \sqrt {a-b+b \sec ^2(e+f x)}}{3 (a-b)^2 f}+\frac {\cos ^3(e+f x) \sqrt {a-b+b \sec ^2(e+f x)}}{3 (a-b) f}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]
time = 1.54, size = 74, normalized size = 0.84 \begin {gather*} \frac {\cos (e+f x) (-5 a+b+(a-b) \cos (2 (e+f x))) \sqrt {(a+b+(a-b) \cos (2 (e+f x))) \sec ^2(e+f x)}}{6 \sqrt {2} (a-b)^2 f} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[Sin[e + f*x]^3/Sqrt[a + b*Tan[e + f*x]^2],x]

[Out]

(Cos[e + f*x]*(-5*a + b + (a - b)*Cos[2*(e + f*x)])*Sqrt[(a + b + (a - b)*Cos[2*(e + f*x)])*Sec[e + f*x]^2])/(
6*Sqrt[2]*(a - b)^2*f)

________________________________________________________________________________________

Maple [A]
time = 0.29, size = 104, normalized size = 1.18

method result size
default \(\frac {\left (a \left (\cos ^{2}\left (f x +e \right )\right )-\left (\cos ^{2}\left (f x +e \right )\right ) b +b \right ) \left (a \left (\cos ^{2}\left (f x +e \right )\right )-\left (\cos ^{2}\left (f x +e \right )\right ) b -3 a +b \right )}{3 f \sqrt {\frac {a \left (\cos ^{2}\left (f x +e \right )\right )-\left (\cos ^{2}\left (f x +e \right )\right ) b +b}{\cos \left (f x +e \right )^{2}}}\, \cos \left (f x +e \right ) \left (a -b \right )^{2}}\) \(104\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(f*x+e)^3/(a+b*tan(f*x+e)^2)^(1/2),x,method=_RETURNVERBOSE)

[Out]

1/3/f*(a*cos(f*x+e)^2-cos(f*x+e)^2*b+b)*(a*cos(f*x+e)^2-cos(f*x+e)^2*b-3*a+b)/((a*cos(f*x+e)^2-cos(f*x+e)^2*b+
b)/cos(f*x+e)^2)^(1/2)/cos(f*x+e)/(a-b)^2

________________________________________________________________________________________

Maxima [A]
time = 0.36, size = 112, normalized size = 1.27 \begin {gather*} -\frac {\frac {3 \, \sqrt {a - b + \frac {b}{\cos \left (f x + e\right )^{2}}} \cos \left (f x + e\right )}{a - b} - \frac {{\left (a - b + \frac {b}{\cos \left (f x + e\right )^{2}}\right )}^{\frac {3}{2}} \cos \left (f x + e\right )^{3} - 3 \, \sqrt {a - b + \frac {b}{\cos \left (f x + e\right )^{2}}} b \cos \left (f x + e\right )}{a^{2} - 2 \, a b + b^{2}}}{3 \, f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)^3/(a+b*tan(f*x+e)^2)^(1/2),x, algorithm="maxima")

[Out]

-1/3*(3*sqrt(a - b + b/cos(f*x + e)^2)*cos(f*x + e)/(a - b) - ((a - b + b/cos(f*x + e)^2)^(3/2)*cos(f*x + e)^3
 - 3*sqrt(a - b + b/cos(f*x + e)^2)*b*cos(f*x + e))/(a^2 - 2*a*b + b^2))/f

________________________________________________________________________________________

Fricas [A]
time = 2.93, size = 79, normalized size = 0.90 \begin {gather*} \frac {{\left ({\left (a - b\right )} \cos \left (f x + e\right )^{3} - {\left (3 \, a - b\right )} \cos \left (f x + e\right )\right )} \sqrt {\frac {{\left (a - b\right )} \cos \left (f x + e\right )^{2} + b}{\cos \left (f x + e\right )^{2}}}}{3 \, {\left (a^{2} - 2 \, a b + b^{2}\right )} f} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)^3/(a+b*tan(f*x+e)^2)^(1/2),x, algorithm="fricas")

[Out]

1/3*((a - b)*cos(f*x + e)^3 - (3*a - b)*cos(f*x + e))*sqrt(((a - b)*cos(f*x + e)^2 + b)/cos(f*x + e)^2)/((a^2
- 2*a*b + b^2)*f)

________________________________________________________________________________________

Sympy [F(-1)] Timed out
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)**3/(a+b*tan(f*x+e)**2)**(1/2),x)

[Out]

Timed out

________________________________________________________________________________________

Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 205 vs. \(2 (84) = 168\).
time = 1.20, size = 205, normalized size = 2.33 \begin {gather*} \frac {{\left (3 \, a \sqrt {b} - b^{\frac {3}{2}}\right )} \mathrm {sgn}\left (f\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right )}{3 \, {\left (a^{2} {\left | f \right |} - 2 \, a b {\left | f \right |} + b^{2} {\left | f \right |}\right )}} + \frac {{\left (a \cos \left (f x + e\right )^{2} - b \cos \left (f x + e\right )^{2} + b\right )}^{\frac {3}{2}} f^{2}}{3 \, {\left (a {\left | f \right |} \mathrm {sgn}\left (f\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) - b {\left | f \right |} \mathrm {sgn}\left (f\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right )\right )} {\left (a f^{2} - b f^{2}\right )}} - \frac {\sqrt {a \cos \left (f x + e\right )^{2} - b \cos \left (f x + e\right )^{2} + b} a}{a^{2} {\left | f \right |} \mathrm {sgn}\left (f\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) - 2 \, a b {\left | f \right |} \mathrm {sgn}\left (f\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right ) + b^{2} {\left | f \right |} \mathrm {sgn}\left (f\right ) \mathrm {sgn}\left (\cos \left (f x + e\right )\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(sin(f*x+e)^3/(a+b*tan(f*x+e)^2)^(1/2),x, algorithm="giac")

[Out]

1/3*(3*a*sqrt(b) - b^(3/2))*sgn(f)*sgn(cos(f*x + e))/(a^2*abs(f) - 2*a*b*abs(f) + b^2*abs(f)) + 1/3*(a*cos(f*x
 + e)^2 - b*cos(f*x + e)^2 + b)^(3/2)*f^2/((a*abs(f)*sgn(f)*sgn(cos(f*x + e)) - b*abs(f)*sgn(f)*sgn(cos(f*x +
e)))*(a*f^2 - b*f^2)) - sqrt(a*cos(f*x + e)^2 - b*cos(f*x + e)^2 + b)*a/(a^2*abs(f)*sgn(f)*sgn(cos(f*x + e)) -
 2*a*b*abs(f)*sgn(f)*sgn(cos(f*x + e)) + b^2*abs(f)*sgn(f)*sgn(cos(f*x + e)))

________________________________________________________________________________________

Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int \frac {{\sin \left (e+f\,x\right )}^3}{\sqrt {b\,{\mathrm {tan}\left (e+f\,x\right )}^2+a}} \,d x \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(sin(e + f*x)^3/(a + b*tan(e + f*x)^2)^(1/2),x)

[Out]

int(sin(e + f*x)^3/(a + b*tan(e + f*x)^2)^(1/2), x)

________________________________________________________________________________________